<%template _header%>
<%namespace YouHP.Model%>
<!--header end-->

<!--TheCurrent start-->
<div id="foruminfo">
	<div class="userinfo">
		<h2><a href="{Config.WebsiteUrl}/Index.aspx" class="home">{Config.WebsiteTitle}</a> 
		<span><a href="{Config.WebsiteUrl}/Member/Manage.aspx">用户中心</a></span>
		<strong>症状记录</strong></h2>
	</div>
	<div class="forumstats">
		<div id="search">
				<%template _quicksearch%>
		</div>
	</div>
</div>
<!--TheCurrent end-->

<!--主体-->
<script type="text/javascript">
	function checkCheckBox(form,objtag)
	{
		if (typeof(objtag.checked) == "undefined")
		{
			objtag.checked = true;
		}
		for(var i = 0; i < form.elements.length; i++) 
		{
			var e = form.elements[i];
			if(e.name == "recordid") 
			{
				e.checked = objtag.checked;
			}
		}
		objtag.checked = !objtag.checked;
	}
</script>
<div class="controlpannel">
   <%template _memmenu%>
	<div class="pannelcontent">
		<div class="pcontent">
			<div class="panneldetail">
				<%template _mempatientmenu%>	
				<div class="pannelbody">
					<div class="pannellist">
					<%if ErrorCount==0%>
						<%if IsPost%>
							<%template _msgbox%>
						<%else%>

						<p>
						   <a href="SymptomRecordes.aspx" class="submitbutton">添加记录</a>&nbsp;&nbsp;
						   <a href="ListSymptomRecordes.aspx?action=1" class="submitbutton">生成图表</a>
						</p><br />

				  		<form id="recordform" name="recordform" method="post" action="">
						<table width="100%" border="0" cellspacing="0" cellpadding="0" ID="Table1">
							<tbody><tr>
								<td></td>
								<td>记录时间</td>
								<td>更新时间</td>
								<td>编辑</td>
								<td>删除</td>
							</tr></tbody>
						<%csharp%>
						int index = SymptomRecordCount;
						foreach(SymptomRecordesInfo info in SymptomRecordList)
						{
						<%/csharp%>
							<tbody>
							<tr class="messagetable" onmouseover="this.className='messagetableon'" onmouseout="this.className='messagetable'">
							<td width="4%"><input name="recordid" id="id{info.Id}" type="checkbox" value="{info.Id}" style="margin-top:-1px;"/></td>
							<td>{info.RecordDate.ToString("yyyy-MM-dd")}</td>
							<td>{info.UpdateDate.ToString("yyyy-MM-dd")}</td>
							<td><a href="AddSymptomRecordes.aspx?id={info.Id}">编辑</a></td>
							<td>
							    <a href="#" onclick="$('id{info.Id}').checked=true;$('recordform').submit();">删除</a></td>
							</tr>
							</tbody>
						<%csharp%>
						}
						<%/csharp%>
						</table>
						</form>
						</div>
						<div class="pannelmessage">
									<div class="pannelleft" style="width: 160px;">
										<a href="javascript:;"  onclick="checkCheckBox($('recordform'),this)" class="selectall">全选</a>&nbsp;&nbsp;&nbsp;
										<a href="#" onclick="$('recordform').submit()" class="selectall">删除</a> 
									</div>
									<div class="pannelright" style="width: 70%;">
											<table width="100%" border="0" cellspacing="0" cellpadding="0">
												<tbody>
													<tr>
														<th class="ticketleft">
															共有记录:{SymptomRecordCount}条
														</th>
													</tr>
												</tbody>
										 </table>
									</div>
						</div>
						</div>
						<%/if%>
					<%else%>
					<%template _memerrmsgbox%>
					<%/if%>
			  </div>
			</div>
		</div>
	</div>
</div>
<!--主体-->
</div>
<%template _copyright%>
<%template _footer%>
